 |
|
 |
Subject: [Edited] Using Eclipse to code Java in Notes/Domino - with a webservice client! |
 |
 |
 |
Product Area: Notes 8 Client |
 |
Technical Area: Functionality |
 |
Platform: Windows XP client |
 |
Release: 8.0.1 |
 |
Reproducible: Not applicable |
 |
 |
 |
 |
Hi
I have coded a relatively large Java web application in Domino 7 - using the Domino Designer IDE (sigh!). The application exposes as well as calls webservices. In version 7 I have "added" Apache Axis to the JVM (not using Stubby from nsftools.com - but a similar approach where I generate the proxy classes in Eclipse).
Now I need to upgrade the webservice client code (due to changes at the external webservices that we call) - and I want to do that using the built-in webservice client code in Notes/Domino. At the same time we want to switch to using Java 1.5 code only (gaining a performance improvement).
Inspired by a couple of sessions (Nik Brauer at LotusPhere 2008, session: AD312 - and Ben Poole at ILUG 2008) I wanted to use Eclipse for my development. The webservice we call is rather complex (the code generated from the WSDL file contains 30-50 classes) and therefore, I would really like to use the type-ahead and debug features of Eclipse. I have had a look at Domiclipse - but it was built for version 7 and does not "know" anything about webservices and as such does not seem to help me.
So far I have almost everything set up and working ;-) ... but I cannot run the webservice client because it is missing it's configuration.
Steps to set this up:
1. In Eclipse add a new JRE (under Preferences). Point the JRE home directory to the JVM library of your Notes client (e.g. C:\lotus\notes\jvm).
2. Create a new Java project in Eclipse and make sure that it uses the JRE that you just created.
3. In Notes, create a Java Library and import a WSDL to generate the Java proxy classes.
4. Export these classes to the file system.
5. Import the proxy classes into Eclipse (using Import - Filesystem).
6. Write a small program to call the webservice (using the suggested code in generated proxy classes)
Now at this time I can actually compile the code!! I can use the type-ahead feature to build the code - using the Lotus Domino webservice classes! This is great!
However, when I want to run my test program to see if things actually work the intended way, I get an error. Basically, it tells me that Axis cannot find any configuration. The last of a good handfull of exceptions in the stack trace looks like this:
lotus.domino.axis.InternalException: lotus.domino.axis.ConfigurationException: lotus.domino.axis.ConfigurationException: No engine configuration file - aborting!
lotus.domino.axis.ConfigurationException: No engine configuration file - aborting!
at lotus.domino.axis.configuration.FileProvider.configureEngine(Unknown Source)
at lotus.domino.axis.AxisEngine.init(Unknown Source)
at lotus.domino.axis.AxisEngine.<init>(Unknown Source)
at lotus.domino.axis.client.Service.getAxisClient(Unknown Source)
at lotus.domino.axis.client.Service.<init>(Unknown Source)
at GetSubjectServiceLocator.<init>(GetSubjectServiceLocator.java:4)
at test.main(test.java:8)
I have tried a couple of things. First, I have tried to locate a client-config.wsdd file (which is the standard Axis client configuration file) on my computer. Without success!
Then I have tried to create a "dummy" file in my project (using the settings in the code from: http://www.nsftools.com/stubby/ApacheAxisClientTips.htm). It did not work. I tried to put the config file in different places in my project (in the root, under bin, pointing at it through a JVM command line option). No success.
Then I tried to use the approach in the nsftools article above. But since Axis has been built into Notes and wrapped up in lotus.domino packages I have not been able to find out how to overwrite the class (in the article it is in org.apache.axis).
[Edit]
I have tried to experiment with the build path:
1. I added my "custom built" client-config.wsdd file to folder in the project and added that folder to the build path. No success.
2. Then I tried to add it to the "src" folder (that is on the build path). No success.
3. Then I tried to add all jar-files in the notes-exe directory (and sub directories) to the build path. No success.
4. Finally, I tried to add all files in the notes-exe directory and notes-data directory to the build path (!). Still no success....
[/Edit]
So close - but something is missing. If someone could make me see what may be obvious I would appreciate that very much!
Thanks in advance!
John
PS. I know there is a deployment issue once the code is working in Eclipse. But that can be solved in different ways. My favourite is using Ant as shown by Nik Brauer at LotusPhere 2008. His code only works for agents - but I assume it could easily be extended to Java Libraries as well.
And I could of course always just copy-paste the source code back to the Notes ;-)
 
Feedback number WEBB7FSC4F created by ~Emile Lopfoogenettu on 06/20/2008


[Edited] Using Eclipse to code Java... (~Emile Lopfooge... 20.Jun.08)
. . Not sure if this will work for you.... (~Dexter Zengero... 20.Jun.08)
. . . . That is "the other end" of the webs... (~Emile Lopfooge... 20.Jun.08)
. . . . . . Did you find a solution? (~Ethan Xanalyik... 2.Sep.08)
. . . . . . . . No... (~Emile Lopfooge... 11.Sep.08)
. . . . . . . . . . Still not solved ? (~Sarah Loptooko... 3.Jun.09)
. . . . . . . . . . . . i have the same problem... (~Nicole Nonhipi... 2.Dec.09) |
|  |
|